﻿using ERPSystem.Common.BaseEntitys;
using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ERPSystem.Common.Domains.SalesOrderCommom
{
    /// <summary>
    /// 销售订单表
    /// </summary>
    [SugarTable("SalesOrder")]
    public class SalesOrder: BaseEntity
    {
        /// <summary>
        /// 主键序号111
        /// </summary>
        [SugarColumn(IsIdentity = true, IsPrimaryKey = true)]
        public int SalesOrderId { get; set; }
        /// <summary>
        /// 单据编码
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string DocumentNumber { get; set; }
        /// <summary>
        /// 单据日期11111
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string DocumentDate { get; set; }
        /// <summary>
        /// 单据状态
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string DocumentStatus { get; set; }
        /// <summary>
        /// 单据类型
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string DocumentType { get; set; }
        /// <summary>
        /// 业务类型
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string BusinessType { get; set; }
        /// <summary>
        /// 业务状态
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string BusinessStatus { get; set; }
        /// <summary>
        /// 部门表名称
        /// </summary>
        
        public int SalesDepartmentName { get; set; }
        /// <summary>
        /// 销售人员
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string SalesStaff { get; set; }
        /// <summary>
        /// 操作表（操作员）
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string OperatorName { get; set; }
        /// <summary>
        /// 销售类型
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string SalesType { get; set; }
        /// <summary>
        /// 供货方式
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string ModeDelivery { get; set; }
        /// <summary>
        /// 客户名称（外键）
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string CustomerProfileName { get; set; }
        /// <summary>
        /// 合同号（上传）
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string ContractNumber { get; set; }
        /// <summary>
        /// 付款条件
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string PaymentTerms { get; set; }
        /// <summary>
        /// 交付日期
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string DeliverDate { get; set; }
        /// <summary>
        /// 交付状态
        /// </summary>
        public int DeliveryStatus { get; set; }
        /// <summary>
        /// 收货人
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)", IsNullable = true)]
        public string Consignee { get; set; }
        /// <summary>
        /// 电话
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(11)", IsNullable = true)]
        public string Phone { get; set; }
        /// <summary>
        /// 地址
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(200)", IsNullable = true)]
        public string Address { get; set; }
        /// <summary>
        /// 目的国家
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(50)", IsNullable = true)]
        public string DestinationCountry { get; set; }
        /// <summary>
        /// 备注信息
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(200)", IsNullable = true)]
        public string NoteInformation { get; set; }
        /// <summary>
        /// 销售订单物料编码（外键）
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(200)", IsNullable = true)]
        public string ItemBianma { get; set; }
    }
}
